/*
 * @Author: miteng 973203639@qq.com
 * @Date: 2024-07-05 15:05:13
 * @LastEditors: miteng 973203639@qq.com
 * @LastEditTime: 2024-07-08 18:39:35
 * @Description:全部注释
 * Copyright (c) 2024-present HBIS Digital Technology Co.,Ltd. All rights reserved.
 */
// import { reactive, onMounted } from 'vue';
// // import system from '@/framework/api/system'
// import systemApi from '@/framework/api/system';

// export function useDict(dictType: Array<string>) {
//   console.log(dictType);
//   const dicts: any = reactive({});

//   onMounted(() => {
//     const ps: Promise<any>[] = [];
//     dictType.forEach((dt, index) => {
//       ps[index] = systemApi.fetchList(dt).then(res => {
//         // return { type: dt, values: res }
//         const obj: object = {
//           type: dt,
//           values: res
//         };
//         console.log(obj);
//         return obj;
//       });
//     });
//     Promise.all(ps).then(res => {
//       res.forEach(val => {
//         // console.log(val,'val')
//         // console.log(val.values,'values')
//         // console.log(dicts,'dicts')
//         dicts[val.type] = val.values.data;
//         // console.log(dicts[val.type].data,'type')
//       });
//     });
//   });
//   // console.log(dicts)
//   return { dicts };
// }
